# • 获取验证码：http://tpshop-test.itheima.net/index.php?m=Home&c=User&a=verify
import requests

response = requests.get("http://tpshop-test.itheima.net/index.php?m=Home&c=User&a=verify")
cook = response.cookies
print(cook)
# 登录成功
# • 登录：http://tpshop-test.itheima.net/index.php?m=Home&c=User&a=do_login
url = "http://tpshop-test.itheima.net/index.php?m=Home&c=User&a=do_login"
ti={
    "username": "13488888888",
    "password": "123456",
    "verify_code": "8888"
}
response = requests.post(url=url , json=ti ,cookies=cook)
print(response.json())
# 查看订单
# • 我的订单：http://tpshop-test.itheima.net/Home/Order/order_list.html

response = requests.get(url="http://tpshop-test.itheima.net/Home/Order/order_list.html" ,cookies=cook)

print(response.text)

